const path = require("path");
const https = require("https");
const fs = require("fs");
module.exports = {
  configureServer(app) {
    https
      .createServer(
        {
          key: fs.readFileSync("server.key"),
          cert: fs.readFileSync("server.cert")
        },
        app
      )
      .listen(4000, function() {
        console.log(
          "Example app listening on port 3000! Go to https://localhost:3000/"
        );
      });
  },
  components: [
    "src/components/**/**/[A-Z]*.jsx",
    "src/pages/**/[A-Z]*.jsx",
    "src/layout/**/[A-Z]*.jsx"
  ],
  moduleAliases: {
    "@components": path.resolve(__dirname, "./src/components"),
    "@store": path.resolve(__dirname, "./src/store"),
    "@layout": path.resolve(__dirname, "./src/layout"),
    "@containers": path.resolve(__dirname, "./src/containers"),
    "@utils": path.resolve(__dirname, "./src/utils"),
    "@services": path.resolve(__dirname, "./src/services"),
    "@assert": path.resolve(__dirname, "./src/assert")
  },
  require: [
    path.join(__dirname, "./node_modules/semantic-ui-css/semantic.min.css")
  ]
};
